package com.matt.domain.care;

import com.fasterxml.jackson.annotation.JsonIgnore;
import com.matt.commons.model.Domain;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;

import javax.persistence.*;


/**
 * 药品交接记录
 */
@Entity
@Data
@Table(name = "hl_handover_record_medicine")
@EqualsAndHashCode(callSuper = true)
@NoArgsConstructor
public class HLHandoverRecordMedicine extends Domain {

    @ManyToOne
    @JoinColumn(name = "handoverRecordId", columnDefinition = "varchar(32) COMMENT '交接记录id'")
    @JsonIgnore
    private HLHandoverRecord handoverRecord;

    @Column(columnDefinition = "varchar(32)  COMMENT '创建人'", nullable = false)
    private String createdBy;

    @Column(columnDefinition = " int(3)  COMMENT '用药方式'")
    private Integer wayVal;

    @Column(columnDefinition = " varchar(10)  COMMENT '用药方式'")
    private String way;

    @Column(columnDefinition = " varchar(2048)  COMMENT '药品照片'")
    private String image;

    @Column(columnDefinition = " varchar(2048)  COMMENT '药品名称'")
    private String name;

    @Column(columnDefinition = " varchar(255)  COMMENT '用药时间'")
    private String daytimeList;

    @Column(columnDefinition = " varchar(32)  COMMENT '每日次数'")
    private String dailyTimes;

    @Column(columnDefinition = " varchar(32)  COMMENT '每次用量'")
    private String quotaPerTime;

    @Column(columnDefinition = " varchar(10)  COMMENT '单位'")
    private String unit;

    @Column(columnDefinition = " varchar(255)  COMMENT '备注'")
    private String remark;
}
